package com.tianjin.design.state;

public class UrgentWorkState implements IWorkState{

	@Override
	public void handle(WorkContext context) {
		if (context.getThing() == 1) {
			System.out.println("设置状态为UrgentWorkState");
			System.out.println("紧急的事情优先做");
		} else {
			context.setState(new NopanicWorkState());
			context.work();
		}
		
	}

}
